package server.io.game.fact;

import java.nio.channels.SelectionKey;
import java.util.HashMap;

import server.io.client.ClientInfo;
import server.io.game.attr.Position_Base;
import server.io.object.Object_Base;

public abstract class Fact_Base extends Object_Base implements Fact_Inter {
	// fact id
	public String fact_id;
	// name
	public String name;
	// 图片资源
	public String imagesrc;
	// 状态
	public String state;
	// 位置信息
	public Position_Base position;

	public Fact_Base(int id, String fact_id, String fact_type) {
		super(id, fact_type);
		this.fact_id = fact_id;
	}
	
	public Fact_Base(int id, String fact_id, String fact_type, Position_Base position) {
		super(id, fact_type);
		this.fact_id = fact_id;
		this.position = position;
	}
	
	
	public Fact_Base() {
		// TODO Auto-generated constructor stub
	}

	/**
	 * 判断是否已存在
	 * @param fact
	 * @return
	 */
	protected boolean judgeExist(Fact_Base fact)
	{
		return this.equal(fact);
	}
}
